<?php
class Antitheft {

	function comparelocation($tagno,$tb_name,$con,$db_name,$latest_location_col,$latestlocation){
	
		$constraint="tag_no='".$tagno."'";
		$refferancelocation=$con->getsinglecells($db_name,$tb_name,$latest_location_col,$constraint);
		echo "Antitheft";
		//echo "<br>Antitheft".$refferancelocation["latest_location"];
		if($latestlocation==$refferancelocation[$latest_location_col]){
			return '1';
		}
		else{
			return '0';
		}
	}
	function notifyuser($db_name,$table,$con,$tag_no,$nofify){
		$contraint="tag_no=".$tag_no;
		$values="notify = 1,";
		$values=$values."antitheft = 0";
		$a=$con->storemulticell($db_name,$con,$table,$values,$contraint);
		return $a;
	}

}
?>